package com.shujia.rec.util

import com.shujia.rec.entry.CaseClass.LogEntry

object LogUtil {


  /**
    * 检查数据格式
    *
    */

  def verifyLog(log: String): Boolean = {

    val flag: Boolean = true


    val split: Array[String] = log.split(",")

    if (split.length != 4) {
      return false
    }

    //其它验证条件
    flag

  }

  /**
    * 将log 转换成LogEntryu
    *
    */

  def toEntry(log: String): LogEntry = {
    val split: Array[String] = log.split(",")
    LogEntry(split(0).toInt, split(1).toInt, split(2).toInt, split(3).toLong)
  }


}
